package com.example.shortlink.entity;

import com.baomidou.mybatisplus.annotation.TableName;

import java.util.Date;

/**
 * @author lihongmin
 * @since 2023/03/06
 **/
@TableName(value = "short_url_map")
public class ShortUrl {

    private Long id;

    private Long postId;

    private String url;

    private String md5;

    private Date createdTime;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getPostId() {
        return postId;
    }

    public void setPostId(Long postId) {
        this.postId = postId;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public String getMd5() {
        return md5;
    }

    public void setMd5(String md5) {
        this.md5 = md5;
    }

    public Date getCreatedTime() {
        return createdTime;
    }

    public void setCreatedTime(Date createdTime) {
        this.createdTime = createdTime;
    }

    @Override
    public String toString() {
        return "ShortUrl{" +
                "id=" + id +
                ", postId=" + postId +
                ", url='" + url + '\'' +
                ", md5='" + md5 + '\'' +
                ", createdTime=" + createdTime +
                '}';
    }
}
